/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package ManagedBeans;

import javax.ejb.EJB;
import javax.faces.bean.ManagedBean;
import javax.faces.bean.SessionScoped;
import sessionBeans.loginSessionBean;

/**
 *
 * @author xespin
 */
@ManagedBean(name="register")
@SessionScoped
public class registerManagedBean {
    @EJB
    private loginSessionBean loginsess;
    
    private String login;
    private String password;

    /** Creates a new instance of registerManagedBean */
    public registerManagedBean(){
    }
    
    public String registerUser(){
        return loginsess.createUser(this.login, this.password);
    }
    public void setLogin(String login) {
        this.login = login;
    }

    public String getLogin() {
        return login;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String getPassword() {
        return password;
    }
       
}
